#!/bin/sh

# 复制项目的文件到对应docker路径，便于一键生成镜像。
usage() {
	echo "Usage: sh copy.sh"
	exit 1
}


# copy sql
echo "begin copy sql "
cp ../../sql/mn-cloud.sql ./mysql/init
cp ../../sql/mn-config.sql ./mysql/init

# copy html
echo "begin copy html "
cp -r ../mengniu-middlewares-ui/dist/** ./nginx/html/dist


# copy jar
echo "begin copy middlewares-gateway "
cp ../middlewares-gateway/target/mengniu-gateway.jar ./mengniu/gateway/jar

echo "mengniu-visual-monitor "
cp ../mengniu-visual/mengniu-monitor/target/mengniu-visual-monitor.jar  ./mengniu/visual/monitor/jar

echo "begin copy middlewares-admin "
cp ../mengniu-modules/middlewares-admin/target/middlewares-admin.jar ./mengniu/modules/admin/jar

echo "begin copy mn-data-sync "
cp ../mengniu-modules/mn-data-sync/target/mn-data-sync.jar ./mengniu/modules/sync/jar

echo "begin copy weimeng-collect "
cp ../mengniu-modules/weimeng-collect/target/weimeng-collect.jar ./mengniu/modules/weimeng-collect/jar

echo "begin copy youzan-collect "
cp ../mengniu-modules/youzan-collect/target/youzan-collect.jar ./mengniu/modules/youzan-collect/jar

